package com.webware.view.client.admin.view;

import com.google.gwt.core.client.GWT;
import com.google.gwt.uibinder.client.UiBinder;
import com.google.gwt.uibinder.client.UiField;
import com.google.gwt.user.cellview.client.CellTree;
import com.google.gwt.user.client.ui.Widget;
import com.webware.view.client.admin.presenter.interfaces.IAdminPageView;
import com.webware.view.client.admin.presenter.interfaces.IAdminPageView.IAdminPagePresenter;
import com.webware.view.client.app.view.ReverseCompositeView;
import com.webware.view.shared.BaseFolder;

public class AdminPageView extends ReverseCompositeView<IAdminPagePresenter>
	implements IAdminPageView {

    private static AdminPageViewUiBinder uiBinder = GWT
	    .create(AdminPageViewUiBinder.class);

    @UiField(provided = true)
    CellTree cellTree;

    interface AdminPageViewUiBinder extends UiBinder<Widget, AdminPageView> {
    }

    public AdminPageView() {
	FolderTreeModel ftm = new FolderTreeModel();
	ftm.getFolders().add(new BaseFolder("Предприятия"));
	ftm.getFolders().add(new BaseFolder("Пользователи"));
	
	cellTree = new CellTree(ftm, null);
	cellTree.setAnimationEnabled(true);
	initWidget(uiBinder.createAndBindUi(this));
    }

    @Override
    public void createView() {

    }
}
